/*
 * @Description: 
 * @Author: zml
 * @Date: 2025-07-25 09:34:10
 * @LastEditors: zml
 * @LastEditTime: 2025-07-29 09:22:19
 */
import { createSlice } from "@reduxjs/toolkit";

//创建counterSlice实例并导出
export const layoutData = createSlice({
  name: 'layoutData',
  //在创建实例时给定state
  initialState: {
    collapsed: false,
  },
  // 不能进行异步操作
  reducers: {
    collapsedcommit: (state, actions) => {
      console.log(actions)
      state.collapsed = actions.payload
    },
  },
});


export const { collapsedcommit } = layoutData.actions;

export default layoutData.reducer;


